<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
    <link rel="stylesheet" href="../dest/index.css" />
  </head>
  <body>
    <div id="app">
      <pl-button label="label"></pl-button>
      <pl-button>BUTTON</pl-button>

      <h4>状态</h4>
      <pl-button
        v-for="item in ['primary', 'success', 'warn', 'error', 'info']"
        :key="item"
        :status="item"
        :label="item"
      ></pl-button>

      <pl-input></pl-input>
      <pl-input status="error" ref="myInput"></pl-input>
      <button @click="outerFocus">outerFocus</button>
    </div>
    <script src="https://cdn.jsdelivr.net/npm/vue@next"></script>
    <script src="../dest/index.js"></script>
    <script>
      console.log('webpack--', window.V3ComponentsMao)
      console.log('vue', Vue)
      const app = window.Vue.createApp({
        setup() {
          const inputRef = window.V3ComponentsMao.Input.use.ref('myInput')

          return {
            outerFocus() {
              inputRef.value.methods.focus()
            }
          }
        }
      })
      app.use(V3ComponentsMao)
      app.mount('#app')
    </script>
  </body>
</html>
